package com.shangxian.giveithome.entity;


import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

@Data
public class UserDetails implements Serializable {


    private Long id;

    /**
     * 小程序唯一标识符
     */
    private String openId;

    /**
     * 昵称
     */
    private String name;

    /**
     * 手机号码
     */
    private String phone;

    /**
     * 头像
     */
    private String picture;

    /**
     * 性别
     */
    private String sex = "";

    /**
     * 志愿时长
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
    private Date volunteerTime;

    /**
     * 微信号码
     */
    private String wechat = "";

    /**
     * 常住地址
     */
    private String address = "";

    /**
     * 用户数据
     */
    private UserData userData;


    /**
     * 是否机构
     */
    private Boolean mechanismStatus = false;

    /**
     * 机构信息
     */
    private Mechanism mechanism;

    /**
     * 角色
     */
    private Integer role;

    /**
     * 额外数据
     */
    private Integer days;

    /**
     * 义工
     */
    private List<VolunteerUser> volunteerUsers;
}
